package com.bocek.chakmapoint.model;

import java.awt.Color;
import java.util.ArrayList;

public class SlideStyleList {
	private int currentStyle;
	
	private static SlideStyleList instance = null;
	private ArrayList<SlideStyle> styles = new ArrayList<SlideStyle>();
	
	private SlideStyleList(){
		styles.add(new SlideStyle("default"));
		currentStyle = 0;
	}
	
	public static SlideStyleList getInstance() {
		if (instance == null) {
			instance = new SlideStyleList();
		}
		return instance;
	}
	
	public void addStyle(String name, Color c, int t, Color b, boolean n){
		styles.add(new SlideStyle(name,c,t,b,n));
	}
	
	public void updateStyle(int index, String name, Color c, int t, Color b, boolean n){
		styles.get(index).update(name,c,t,b,n);
	}
	
	public SlideStyle getStyle(int index){
		return styles.get(index);
	}
	
	public void setCurrentStyle(int index){
		this.currentStyle = index;
	}
	
	public int getCurrent(){
		return currentStyle;
	}
}
